---
title: "SQL-VP-026: Look up external client email address by system user (Oracle)"
summary: Looks up an external client's email address by mail ID and last name via an Oracle procedure.
status: draft
owner: SAIF Claims BOF team
last_reviewed: 2026-08-21
library: SAIF.Business.View.Policy
reference_type: embedded
---

# SQL-VP-026 Look up external client email address by system user (Oracle)

Used by `clsTeamAssignment.InitializeEmailAddressUsingSystemUser()`, an Oracle-side alternative to
[SQL-VP-025](SQL-025-cp_external_client_lookup.md).

## Classification

| Field | Value |
| --- | --- |
| **SQL ID** | SQL-VP-026 |
| **Operation type** | Read |
| **Execution method** | Stored procedure (scalar function via `ReturnValue`) |
| **Database** | Oracle |
| **Schema** | `[unqualified]**` |
| **Command type** | StoredProcedure |
| **Business object** | `clsTeamAssignment` |
| **Criteria property** | `InitializeEmailAddressUsingSystemUser()` (ad hoc method) |
| **Lifecycle method** | ad hoc method |

## Parameters

| Parameter | Direction | Type | Max length | Description |
| --- | --- | --- | --- | --- |
| `in_mailid` | Input | String | N/A | Mail/system-user ID. |
| `in_last_name` | Input | String | N/A | Client last name. |
| `out_external_email` | ReturnValue | String | N/A | Resolved external email address. |

## Tables

| Table | Access | Columns used |
| --- | --- | --- |
| *(not directly visible — encapsulated in procedure body)* | SELECT | N/A |

## Sample SQL

```sql
BEGIN
  :out_external_email := sp73341_external_client_lookup(
    in_mailid    => :in_mailid,
    in_last_name => :in_last_name
  );
END;
```

*Call signature reconstructed from `DataRequest.SQLStatement`/`AddParm` calls; the procedure body
resides in the Oracle database and was not retrieved this run.*

> **Note:** Statements marked with `*` were inferred from code structure, naming
> conventions, or contextual evidence where direct confirmation was not available
> in source artifacts. Statements marked with `**` could not be confirmed; treat
> as unknown until verified.

## Sources
- `SAIF.Business.View.Policy\clsTeamAssignment.vb`
